<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<body>
    <div id="app">
        <cpn></cpn>
        <cpn></cpn>
    </div>
    <script src="../vue.js"></script>
    <script>
        const cpnC = Vue.extend({
            template:`
            <div>
                <h2>header</h2>
                <p>content,hahhaahah</p>
                <p>content,hehehheheh</p>
            </div>`
        })
        const app = new Vue({
            el: '#app',
            // 挂在在实例下面注册
            components:{
                cpn: cpnC
            }
        })
    </script>
</body>
</html>